﻿<Window x:Class="RegeditNavigator.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:tb="http://www.hardcodet.net/taskbar"
        xmlns:local="clr-namespace:RegeditNavigator"
        Title="Registry Editor Navigator" Height="Auto" Width="400" SizeToContent="WidthAndHeight" WindowStyle="ToolWindow" Icon="RegEdit.ico" Loaded="OnLoaded"
        Name="Main" WindowStartupLocation="CenterScreen">
    <DockPanel Height="Auto">
        <DockPanel.Resources>
            <local:ShowCommand x:Key="Show"/>
        </DockPanel.Resources>
        <tb:TaskbarIcon Name="NotifyIcon" IconSource="RegEdit.ico" ToolTipText="Registry Editor Navigator" 
                        LeftClickCommand="{StaticResource Show}" 
                        LeftClickCommandParameter="{Binding ElementName=Main}"
                        DoubleClickCommand="{StaticResource Show}" 
                        DoubleClickCommandParameter="{Binding ElementName=Main}">
            <tb:TaskbarIcon.ContextMenu>
                <ContextMenu>
                    <MenuItem Header="Open" Click="Show"/>
                    <Separator/>
                    <MenuItem Header="Exit" Click="Exit"/>    
                </ContextMenu>
            </tb:TaskbarIcon.ContextMenu>
        </tb:TaskbarIcon>
        <StatusBar Name="StatusBar" DockPanel.Dock="Bottom" Visibility="Collapsed">
            <DockPanel LastChildFill="True">
                <Image DockPanel.Dock="Left" Margin="2,0" Name="StatusIcon" Width="16"></Image>
                <TextBlock VerticalAlignment="Bottom" Margin="2,0" Name="StatusText"></TextBlock>
            </DockPanel>
        </StatusBar>
        <Button ToolTip="Navigate" HorizontalAlignment="Right" VerticalAlignment="Top" DockPanel.Dock="Right" Click="Go" IsDefault="True">
            <Image Source="navigate.ico" Width="16" Height="16"/>
        </Button>
        <TextBox HorizontalAlignment="Stretch" Text="HKLM\Software\Microsoft" VerticalAlignment="Top" Name="Path"/>
    </DockPanel>
</Window>
